package cn.fcq.basic.mapper;

import cn.fcq.basic.query.BaseQuery;

import java.util.List;

public interface BaseMapper<T> {
    //新增
    void save(T t);

    //修改
    void update(T t);

    //根据id删除
    void deleteById(Long id);

    //查询所有
    List<T> loadAll();

    //根据ID查询
    T loadById(Long id);

    //查询总条数
    Long queryCount(BaseQuery query);

    //查询当前页的数据
    List<T> queryData(BaseQuery query);
    //批量删除
    void batchRemove(List<Long> ids);
}
